package com.yilouwangye.mvc;

public class MVCStudentPattern {
//    private static Student retrieveStudentFromDatabase(){
//        Student student = new Student();
//        student.setName("cat");
//        student.setRoollNo("8");
//        return student;
//    }

    public static void main(String[] args) {
        // 从数据库获取学生信息
        Student model = new Student();
        // 创建试图，输出到控制台
        StudentView view = new StudentView();
        StudentController studentController = new StudentController(model,view);
        // 更新模型数据
//        studentController.updateView();
        studentController.setStudentName("jean");
        studentController.setStudentRollNo("16");
        studentController.updateView();
    }
}
